package TestDemo3;

class A{
    int a;
    public A() {
        func();
    }
    void func() {
        System.out.println("A func()");
    }
}
class B extends A{
    int a=10;
   public void func() {
       System.out.println("B func()"+a);
   }
}
public class Test2 {
    public static void main(String[] args) {
        B p=new B();
    }
}
